package com.song.dubbo.client.controller;

import com.song.dubboapi.service.TestService;
import org.apache.dubbo.config.annotation.DubboReference;
import org.apache.dubbo.rpc.RpcContext;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping(path = "/test")
public class TestController {

    @DubboReference(group = "cus", loadbalance = "song")
    private TestService testService ;

    @GetMapping(path = "/get/server/info")
    public String getString(){

        return testService.getServerinfo("313");
    }

}
